/*
测试更新
Navicat MySQL Data Transfer

Source Server         : mysql
Source Server Version : 50527
Source Host           : localhost:3306
Source Database       : bocai

Target Server Type    : MYSQL
Target Server Version : 50527
File Encoding         : 65001

Date: 2015-06-18 22:38:04
*/

SET FOREIGN_KEY_CHECKS=0;

-- ----------------------------
-- Table structure for `bc_admin`
-- ----------------------------
DROP TABLE IF EXISTS `bc_admin`;
CREATE TABLE `bc_admin` (
`USER_ID`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '后台用户主键' ,
`USERNAME`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '用户名' ,
`PASSWORD`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '密码' ,
`EMAIL`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '电子邮件' ,
`REGISTER_TIME`  date NULL DEFAULT NULL COMMENT '注册时间' ,
`REGISTER_IP`  varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '注册时使用的IP' ,
`LOGIN_COUNT`  int(11) NULL DEFAULT NULL COMMENT '登录次数' ,
`IS_ADMIN`  char(1) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '是否为超级用户：0：否；1：是' ,
`REMARKS1`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS2`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS3`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
PRIMARY KEY (`USER_ID`)
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_admin
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `bc_collect`
-- ----------------------------
DROP TABLE IF EXISTS `bc_collect`;
CREATE TABLE `bc_collect` (
`Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '收藏主键' ,
`BC__USER_ID`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '用户主键' ,
`User_Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '用户id' ,
`Pic_Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '图片表id' ,
`Col_Message`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '收藏信息' ,
`Col_Time`  date NULL DEFAULT NULL COMMENT '收藏时间' ,
`REMARKS1`  varbinary(32) NULL DEFAULT NULL ,
`REMARKS2`  varbinary(32) NULL DEFAULT NULL ,
`REMARKS3`  varbinary(32) NULL DEFAULT NULL ,
`REMARKS4`  varbinary(32) NULL DEFAULT NULL ,
`REMARKS5`  varbinary(32) NULL DEFAULT NULL ,
PRIMARY KEY (`Id`),
FOREIGN KEY (`Id`) REFERENCES `bc_picture` (`Id`) ON DELETE RESTRICT ON UPDATE RESTRICT,
FOREIGN KEY (`BC__USER_ID`) REFERENCES `bc_user` (`USER_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT,
INDEX `FK_Reference_1` (`BC__USER_ID`) USING BTREE 
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_collect
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `bc_linktble`
-- ----------------------------
DROP TABLE IF EXISTS `bc_linktble`;
CREATE TABLE `bc_linktble` (
`Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户主键' ,
`LinkType_Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '链接类型i' ,
`Link_Name`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '链接名称' ,
`Link_Address`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '链接地址' ,
`Activate`  char(1) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '是否显示' ,
`Link_Sort`  int(5) NULL DEFAULT NULL COMMENT '显示顺序' ,
`WEIGHT`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '权重' ,
`REMARKS1`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS2`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS3`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
PRIMARY KEY (`Id`),
FOREIGN KEY (`Id`) REFERENCES `bc_linktype` (`Id`) ON DELETE RESTRICT ON UPDATE RESTRICT
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_linktble
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `bc_linktype`
-- ----------------------------
DROP TABLE IF EXISTS `bc_linktype`;
CREATE TABLE `bc_linktype` (
`Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户主键' ,
`Type_Name`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '链接类型名称' ,
`REMARKS1`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS2`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS3`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
PRIMARY KEY (`Id`)
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_linktype
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `bc_picture`
-- ----------------------------
DROP TABLE IF EXISTS `bc_picture`;
CREATE TABLE `bc_picture` (
`Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '商品属性主键' ,
`Type_Id`  varbinary(32) NULL DEFAULT NULL COMMENT '类别id' ,
`PicName`  varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '中文名称' ,
`Desctibe`  varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '录入方式：1.树状菜单，2.单选，3.复选，4.文本框' ,
`Periods`  int(11) NULL DEFAULT NULL COMMENT '期数' ,
`UrlAddress`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '连接地址' ,
`Pic_Mold`  char(1) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '图片的类型（大图还是略缩图）1为大0为小' ,
`Is_Show`  int(1) NULL DEFAULT NULL COMMENT '是否前台显示：0.为否 1.为是' ,
`is_Recommend`  char(1) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '是否为推荐' ,
`Feature_Sort`  int(11) NULL DEFAULT NULL COMMENT '前台显示排序' ,
`REMARKS1`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS2`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS3`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS4`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS5`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
PRIMARY KEY (`Id`),
FOREIGN KEY (`Id`) REFERENCES `bc_type` (`Id`) ON DELETE RESTRICT ON UPDATE RESTRICT
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_picture
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `bc_type`
-- ----------------------------
DROP TABLE IF EXISTS `bc_type`;
CREATE TABLE `bc_type` (
`Id`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '类目主键。(本系统目前就一个图片)' ,
`Typ_Name`  varchar(80) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '类目名称' ,
`Typ_Describe`  varchar(80) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '类目描述' ,
`Typ_Sort`  int(11) NULL DEFAULT NULL COMMENT '前台显示排序' ,
`PARENT_TYPE`  varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '父类目' ,
`REMARKS1`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '备用字段' ,
`REMARKS2`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS3`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS4`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS5`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
PRIMARY KEY (`Id`)
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_type
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `bc_user`
-- ----------------------------
DROP TABLE IF EXISTS `bc_user`;
CREATE TABLE `bc_user` (
`USER_ID`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户主键' ,
`USERNAME`  varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '用户名' ,
`PASSWORD`  varchar(32) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '密码' ,
`EMAIL`  varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '电子邮件' ,
`REGISTER_TIME`  date NULL DEFAULT NULL COMMENT '注册时间' ,
`REGISTER_IP`  varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '注册时使用的IP' ,
`LOGIN_COUNT`  int(11) NULL DEFAULT NULL COMMENT '登录次数' ,
`REMARKS1`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS2`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`REMARKS3`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
PRIMARY KEY (`USER_ID`)
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of bc_user
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `person`
-- ----------------------------
DROP TABLE IF EXISTS `person`;
CREATE TABLE `person` (
`person_id`  int(32) NOT NULL DEFAULT 0 ,
`name`  varchar(16) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`gender`  int(3) NULL DEFAULT NULL ,
`person_addr`  varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`birthday`  date NULL DEFAULT NULL ,
PRIMARY KEY (`person_id`)
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of person
-- ----------------------------
BEGIN;
INSERT INTO `person` VALUES ('1', '张碱', '23', '32', '2015-06-09');
COMMIT;

-- ----------------------------
-- Table structure for `person_user`
-- ----------------------------
DROP TABLE IF EXISTS `person_user`;
CREATE TABLE `person_user` (
`id`  int(32) NOT NULL DEFAULT 0 ,
`pid`  int(32) NULL DEFAULT NULL ,
`uid`  int(32) NULL DEFAULT NULL ,
PRIMARY KEY (`id`)
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of person_user
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for `user`
-- ----------------------------
DROP TABLE IF EXISTS `user`;
CREATE TABLE `user` (
`id`  int(32) NULL DEFAULT NULL ,
`name`  varchar(16) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
`age`  int(3) NULL DEFAULT NULL 
)
ENGINE=InnoDB
DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci

;

-- ----------------------------
-- Records of user
-- ----------------------------
BEGIN;
COMMIT;